package mobilefeel;

import java.io.Serializable;

/**
 * Used for receiving notifications when an Android device connects,
 * disconnects or sends Custom Data (Serilizable objects)
 * */
public interface DeviceListener {

	/**
	 * Called when an Android device connects to the application.
	 * 
	 * @param device the {@link AndroidDevice} that has connected
	 */
	void onDeviceConnected(AndroidDevice device);
	
	/**
	 * Called when an Android device disconnects from the application.
	 * 
	 * @param device the {@link AndroidDevice} that has disconnected
	 */
	void onDeviceDisconnected(AndroidDevice device);
	
	/**
	 * Called when an Android device sends Custom Data (Serilizable objects)
	 * to the application.
	 * 
	 * @param device the {@link AndroidDevice} that has sent custom data
	 * @param text a String defining the type of information being sent
	 * @param object the Serilizable object
	 */
	void onCustomDataReceived(AndroidDevice device, String text, Serializable object);
	
}
